home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Pascal Super Library
/
Pascal Super Library (CW International)(1997).bin
/
LIBRARY
/
SHDK_2
/
TEST.PAS
< prev
next >
Wrap
Pascal/Delphi Source File
|
1989-05-02
|
527b
|
20 lines
program TestExecSwap;
uses
Dos,ExecSwap; {Keep ExecSwap last}
const
SwapLoc : array[Boolean] of String[7] = ('on disk', 'in EMS');
var
Status : Word;
begin
UseEmsIfAvailable := True;
if not InitExecSwap(HeapPtr, 'SWAP.$$$') then
WriteLn('Unable to allocate swap space')
else begin
WriteLn('Allocated ', BytesSwapped, ' bytes ', SwapLoc[EmsAllocated]);
SwapVectors;
Status := ExecWithSwap(GetEnv('COMSPEC'), '');
SwapVectors;
WriteLn('Exec status: ', Status);
end;
end.